<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE HTML>
<html class="">
<head>
	
	<meta name="author" content="蓝凌科技">
	<meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
	<meta name="format-detection" content="telephone=no">
	<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
	<meta http-equiv="Pragma" content="no-cache" />
	<meta http-equiv="Expires" content="0" />

	<link rel="stylesheet" type="text/css" href="/Public/Api/css/sm.min.css">	
	<link rel="stylesheet" type="text/css" href="/Public/Api/css/sm-extend.min.css">	
	
	<title>帮工小哥</title>
	
	<script type="text/javascript">
	    var _root = '<?php echo ($_site_url); echo U(' / ');?>', _controller = '<?php echo ($_controller); ?>';
	</script>
	
	
	<link rel="stylesheet" type="text/css" href="/Public/Api/css/order.css">


</head>
<body>
	
	

<div class="page-group">
    <div class="page page-current">
        <div class="content my-order-coupon">
            <!--优惠券1-->
            <div class="list-block media-list">
                <ul>
                	<?php if(!empty($list)): if(!empty($list['available'])): if(is_array($list['available'])): foreach($list['available'] as $key=>$coupon): ?><li onclick="window.location.href='<?php echo U('WeChatApi/jsApiCall', 'order_id='.$order_id.'&coupon_id='.$coupon['coupon_id']);?>'">
			                        <label class="label-checkbox item-content">
			                            <div class="item-inner">
			                                <div class="coupon">
			                                    <div class="coupon-text">
			                                        <p>帮工小哥</p>
			                                        <div class="coupon-detail clearfix">
			                                            <span class="left coupon-money">￥<?php echo ($coupon['money']); ?></span>
			                                            <div class="coupon-use right">
			                                                <p>本次可使用</p>
			                                                <p class="coupon-date"><?php echo (GetDateMk($coupon['create_time'])); ?>--<?php echo (GetDateMk($coupon['deadline'])); ?></p>
			                                            </div>
			                                        </div>
			                                    </div>
			                                    <!--使用优惠条件-->
			                                    <div class="condition">
			                                        <ul>
			                                            <li>
			                                            	<i class="list-disc"></i>
			                                            	<?php if($coupon["minimum"] == '0'): ?>定额优惠
			                                            	<?php else: ?>
			                                            		满<?php echo ($coupon['minimum']); ?>元可用<?php endif; ?>
			                                            </li>
			                                            <li><i class="list-disc"></i>优惠码 <?php echo ($coupon['code']); ?></li>
			                                        </ul>
			                                    </div>
			                                </div>
			                            </div>
			                        </label>
			                    </li><?php endforeach; endif; endif; ?>
			            
			            <?php if(!empty($list['unavailable'])): if(is_array($list['unavailable'])): foreach($list['unavailable'] as $key=>$coupon): ?><li>
			                        <label class="label-checkbox item-content">
			                            <div class="item-inner">
			                                <div class="coupon coupon-dis">
			                                    <div class="coupon-text">
			                                        <p>帮工小哥</p>
			                                        <div class="coupon-detail clearfix">
			                                            <span class="left coupon-money">￥<?php echo ($coupon['money']); ?></span>
			                                            <div class="coupon-use right">
			                                                <p>本次不可使用</p>
			                                                <p class="coupon-date"><?php echo (GetDateMk($coupon['create_time'])); ?>--<?php echo (GetDateMk($coupon['deadline'])); ?></p>
			                                            </div>
			                                        </div>
			                                    </div>
			                                    <!--使用优惠条件-->
			                                    <div class="condition">
			                                        <ul>
			                                            <li>
			                                            	<i class="list-disc list-disc-gray"></i>
			                                            	<?php if($coupon["minimum"] == '0'): ?>定额优惠
			                                            	<?php else: ?>
			                                            		满<?php echo ($coupon['minimum']); ?>元可用<?php endif; ?>	
			                                            </li>
			                                        </ul>
			                                    </div>
			                                </div>
			                            </div>
			                        </label>
			                    </li><?php endforeach; endif; endif; ?>
		            <?php else: ?>
		            	暂无可用优惠券<?php endif; ?>
                    <!--失效的优惠券-->
                    
                </ul>
            </div>
        </div>
    </div>
</div>




	<!-- 底部
================================================== -->
<footer>
</footer>
<script type="text/javascript">
    (function(){
        var ThinkPHP = window.Think = {
            "ROOT"   : "", //当前网站地址
            "APP"    : "/api.php?s=", //当前项目地址
            "PUBLIC" : "/Public", //项目公共目录地址
            "DEEP"   : "<?php echo C('URL_PATHINFO_DEPR');?>", //PATHINFO分割符
            "MODEL"  : ["<?php echo C('URL_MODEL');?>", "<?php echo C('URL_CASE_INSENSITIVE');?>", "<?php echo C('URL_HTML_SUFFIX');?>"],
            "VAR"    : ["<?php echo C('VAR_MODULE');?>", "<?php echo C('VAR_CONTROLLER');?>", "<?php echo C('VAR_ACTION');?>"]
        }
    })();
    
</script>
<script src="/Public/Api/js/zepto.min.js" type="text/javascript">
</script>
<script type="text/javascript">
//坑死人的配置项
//若不加此配置，则所有页面均使用 js 和 css 缓存
$.config = {
   	router: false
}
</script>
<script src="/Public/Api/js/sm.min.js" type="text/javascript">
</script>
<script src="/Public/Api/js/sm-extend.min.js" type="text/javascript">
</script>
<script src="/Public/Api/js/think.js" type="text/javascript">
</script>


<script type="text/javascript">




</script>

<!-- 用于加载js代码 -->

</body>
</html>